1. Field of the Invention
The present invention relates generally to three-dimensional (3D) modeling, animation, effects, and rendering applications, and in particular, to a method, apparatus, and article of manufacture for preserving the shape of an object when mapping an object to a surface in a 3D model.
2. Description of the Related Art
In 3D modeling, animation, effects, and rendering applications, it is desirable to place and display one object (referred to as a detail model) onto another object (referred to as a destination). For example, a company logo may be copied or placed onto the front hood of an automobile or the side of a shoe. In another example, a semi-soft rubber disc may be wrapped around a cylindrical surface. With such an application/effect, it may be desirable for the detail model to conform to a curved destination surface yet retain its detail model proportions. However, in the prior art, such shape preservation was not possible. Such problems may be better understood with a description of prior art mapping applications.
It is well known that in general a curved surface cannot be flattened to a planar surface without either distortion or tearing. The converse is also true: that a planar surface cannot be mapped to a curved surface without distortion or tearing. The mapping distortion can be managed in various ways. A conformal mapping (also referred to as a shape preserving mapping), for example, locally preserves shape. A shape preserving mapping is a map of one region to another that is one-to-one and continuous and such that angles are preserved. In particular, maps that preserve the form (or shape) of small-scale features are called “conformal” or “shape preserving”. References herein to shape preservation and shape distortion are construed at small or local scales. At large scales, shape preservation is generally not possible.
Given a 3D detail model that is defined over a reference plane, the prior art is unable to create a copy of the detail model that conforms to a curved destination yet retains the original detail model proportions. While prior art applications may allow for the projection or mapping of a detail model plane to a destination surface (e.g., via a UV parameterization of the destination surface), such a parameterization may not provide for shape preserving mapping. Accordingly, undesirable distortions may result. For example, a 3D detail model geometry may be applied to a destination surface using the existing parameterization of the destination surface. If such an original parameterization is not shape preserving, shape distortion will result. Further, the entire detail model would distort based on the use of the original parameterization. The Rhinoceros™ NURBS modeling for Windows™ application (referred to herein as Rhino™) provides such a mapping with shape distorting results.
Alternative prior art applications (e.g., Autodesk™ ImageStudio available from the assignee of the present invention) may provide the ability to map a texture to a surface (such workflow referred to as “decal mapping”) in a shape preserving manner. However, the destination surface is first tessellated into a mesh and it is not possible to map the detail model decal to the original smooth surface. In other words, the detail model decal is mapped onto the tessellated surface. However, when mapping to a mesh, a very detailed, refined tessellation is necessary to accurately represent the original destination surface. Such a fine mesh may require tens or hundreds of thousands of triangles resulting in slow processing and problems with the high volume of data that is being used. In addition, since a mesh is a non-smooth surface (i.e., it is piecewise linear), any mapping or display that utilizes such a mesh may result in artifacts.
In addition, the prior art may utilize texture mapping that often relies on a particular graphics engine, rendering software, or hardware graphics processing unit (GPU). Such a reliance limits the flexibility of the application and does not allow the use of new or different parameterizations for a destination surface. Further, such texture mapping does not provide the ability to map a 3D detail model (i.e., geometry) onto a smooth destination surface. Instead, prior art texture mapping is limited to a 2D texture map detail model, or, at best, the conversion of 2D texture into surface displacement (known as displacement mapping).